06. Package Spring Boot Application

035ND C01 L04 A23 PACKAGE SPRINGBOOT

035ND C01 L04 A24 WHY PACKAGE

IntelliJ Maven Plugin

035ND C01 L04 A25 INTELLIJ MAVEN PLUGIN

Spring boot packages type

035ND C01 L04 A26 SPRINGBOOT PACKAGE TYPES

There are two types of packaging options available for a spring boot application. One is to pack it into a jar file, another option is to pack it into a war file.

.jar files: The .jar files contain libraries, resources and accessories files like property files.

.war files: The war file contains the web application that can be deployed on any servlet/jsp container. The .war file contains jsp, html, javascript and other files necessary for the development of web applications.

By default, spring boot application will be packed into jar file. If want to pack as war file. You need to add the following attributes in pom.xml.

<packaging>war</packaging>
<name>packing</name>

Spring Boot packing Quiz

Which of the following is true about a SNAPSHOT build?

SOLUTION: All of the above.

Spring Boot Packing

035ND C01 L04 A27 SPRINGBOOT PACKAGING

Spring Boot maven package quiz

Which of the following plugin runs the JUnit unit tests and creates test reports?

SOLUTION: surefile

Run artifact

035ND C01 L04 A28 RUN ARTIFACTS

Try packing yourself

Please try to package the websocket application yourself, and see if you can run it.

Running artifact with flags

035ND C01 L04 A29 ARTIFACT WITH FLAGS

Maven Command Quiz 1

Which of the following commands can be used to look at the default configuration of the super POM?

SOLUTION: mvn help:effective-pom

Maven lifeCycle Quiz

Which of the following phase in maven life cycle processes the generated files from the test code file compilation?

SOLUTION: process-test-classes

035ND C01 L04 A30 LESSON SUMMARY

Summary

035ND C01 L04 A31 COURSE SUMMARY